package com.hengshan.domain.vo;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.hengshan.domain.entity.Role;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.experimental.Accessors;

import java.util.Date;
import java.util.List;

@Data
@AllArgsConstructor
@NoArgsConstructor
@JsonInclude(JsonInclude.Include.NON_NULL)
@Accessors(chain = true)
public class UserInfoVo {

    //ID
    private Long id;

    //用户名
    private String username;

    //头像
    private String avatar;

    //邮箱
    private String email;

    //性别：0女 1男
    private String sex;

    //手机号码
    private String phone;

    //账号状态：0停用 1正常
    private String status;

    //权限信息
    private List<String> permissions;

    //角色信息
    private List<Role> roles;

    //角色id
    private Integer[] roleIds;

    //创建时间
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    private Date createTime;
}
